home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Mac100% 1998 November
/
MAC100-1998-11.ISO.7z
/
MAC100-1998-11.ISO
/
オンラインソフト定点観測
/
ユーティリティ
/
Mops 3.2.sea
/
Mops 3.2
/
Mops source
/
PPC source
/
qArgs
< prev
next >
Wrap
Text File
|
1998-05-25
|
2KB
|
79 lines
(*
Note: -> is defined in qCond, not here.
This file is derived from Args. It contains any defns from Args that:
1. are needed for the PPC image as compiled on the 68k.
2. have to be compiled BEFORE we start compiling PPC code - i.e. before
GO at the beginning of Setup.
So, here we only have to include words that generate 68k code, but
which for some reason get EXECUTED after GO-time. And of course if
the definition is identical in Base, we can omit it here.
Thus we only include words which are immediate, or which get executed
at compile time, AND are different from their original versions in Base
(e.g. words which need to refer to CDP rather than DP).
*)
¥ Support for named parms and local variables
¥ I think all we need here is the local section stuff. We also
¥ need INLINE{, but we've already included this in file cg5 where
¥ it makes more sense (since the inline_h handler is there.
¥ Special note: since qClass uses local sections, which must use the
¥ 68k implementation of course, we must load this AFTER qClass,
¥ although this isn't the "proper" order.
: LOCAL
local? ?error 93 1 -> local? ¥ We change it to the normal -1
¥ as soon as "{" is read.
postpone : drop
postpone [
CDP -> loc_addr
$ 48000000 code, ¥ uncond branch to be resolved by :loc
postpone reveal ¥ local section name must be visible
;
: :LOC
local? 1 = IF msg# 96 THEN ¥ warning - no locals defined
?loc
' drop ¥ gobble word name
CDP -> const_data_start
$ BE020000 code, ¥ marks this as the :loc position
¥ (just for disassembly)
false -> method?
false -> local? ¥ so entry sequence gets compiled
false ppc_entry ¥ handle ppc proc entry
drop 304 ¥ security marker for :loc
curr-def
loc_addr -> curr-def
PLentry
-> curr-def
frameSize IF initTemps THEN
; immediate
: ;LOC
304 ?defn
false -> leaf? ¥ let's just reduce the bug possibilities!
loc_addr 2- (;)
loc_addr curr-def resolve_unconditional_branch
¥ finally resolve the forward branch
¥ from LOCAL
; immediate
: ?ERROR ¥ ( b -- ) Aborts and prints resource string if true.
¥ Usage: ?error 999
postpone if
intrp1 ( get err# ) postpone literal postpone die
postpone then ; immediate